package com.atguigu.gmall.feign.seckill;

import com.atguigu.gmall.common.result.Result;
import com.atguigu.gmall.model.order.vo.OrderConfirmVo;
import com.atguigu.gmall.model.seckill.entity.SeckillGoods;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;

import java.util.List;

@FeignClient("service-seckill")
@RequestMapping("/api/inner/seckill")
public interface SeckillFeignClient {


    @GetMapping("/getSecKillGoods")
    Result<List<SeckillGoods>> getSecKillGoods();

    @GetMapping("/detail/{skuId}")
    Result<SeckillGoods> getDetail(@PathVariable Long skuId);

    @GetMapping("/getSeckillOrder/{skuIdStr}")
    Result<OrderConfirmVo> getSeckillOrder(@PathVariable String skuIdStr);
}


